package org.dev.pf.iof.systemmanage.action;

import org.apache.commons.lang3.StringUtils;
import org.dev.pf.iof.base.action.AbstractCommonAction;
import org.dev.pf.iof.base.constants.IofConstants;
import org.dev.pf.iof.base.vo.LoginInfo;

public class SecurityAction extends AbstractCommonAction{

	/**
	 * 
	 */
	private static final long serialVersionUID = 1L;
	
	
	private String userNO;
	
	private String passWord;
	
	public String getUserNO() {
		return userNO;
	}
	
	public void setUserNO(String userNO) {
		this.userNO = userNO;
	}

	public String getPassWord() {
		return passWord;
	}

	public void setPassWord(String passWord) {
		this.passWord = passWord;
	}




	public String login()throws Exception{
		if(StringUtils.equals(userNO, passWord)){
			getSession().setAttribute(IofConstants.IOF_LOGININFO, new LoginInfo(userNO));
			return SUCCESS;
		}
		return INPUT;
	}
	
	public String initMeun()throws Exception{
		
		return SUCCESS;
	}

}
